<!DOCTYPE html>
<html class="x-admin-sm" xmlns:th="http://www.thymeleaf.org">

<!--1、Head：标题、css-->
<head th:replace="admin_fragments :: head(用户表单弹出框)"></head>

<!--2、JS-->
<div th:replace="admin_fragments :: script"></div>

<!--3、内容-->
<body>
<div style=" width:500px; margin:50px auto">

    <form class="layui-form" th:action="@{/user/page/updateForm}" method="post" id="changefileform"
          style="margin-top: 30px">
        <!--1、用户id-->
        <input type="hidden" name="userId" th:value="${session.user.userId}">

        <!--2、昵称-->
        <div class="layui-form-item">
            <div class="layui-inline">
                <label class="layui-form-label">新用户</label>
                <div class="layui-input-inline">
                    <input type="text" name="userName" autocomplete="off" class="layui-input">
                </div>
            </div>
        </div>

        <!--4、邮箱-->
        <div class="layui-form-item">
            <div class="layui-inline">
                <label class="layui-form-label">新邮箱</label>
                <div class="layui-input-inline">
                    <input type="email" name="userEmail" autocomplete="off" class="layui-input">
                </div>
            </div>
        </div>

        <div class="layui-form-item">
            <div class="layui-inline">
                <label class="layui-form-label">现年龄</label>
                <div class="layui-input-inline">
                    <input type="text" name="userAge" autocomplete="off" class="layui-input">
                </div>
            </div>
        </div>

        <!--5、密码-->
        <div class="layui-form-item">
            <label class="layui-form-label">新密码</label>
            <div class="layui-input-inline">
                <input type="password" name="userPassword" placeholder="请输入密码" class="layui-input"
                       lay-verify="type|required">
            </div>
            <div class="layui-form-mid layui-word-aux">请填写6到12位（系统自动加密前：初始密码）</div>
        </div>

        <div class="layui-form-item">
            <div class="layui-input-block">
                <button type="submit" class="layui-btn" lay-submit="" lay-filter="demo1" onclick="save()">提交</button>
                <button type="reset" class="layui-btn layui-btn-primary">重置</button>
            </div>
        </div>
    </form>
</div>
</body>

<script>

    function save() {
        layer.msg('用户信息修改成功！', {icon: 1});
    }
</script>
</html>